#pragma once

namespace HotKeyOperation
  {
//------------------------------------------------------------------------

  class IOperation
    {
    public:
      IOperation(){};
      IOperation(unsigned int i_delay_before, unsigned int i_delay_after);

      void Operate();

      void AddOperation(IOperation * i_ioperation);


    private:
      friend class boost::serialization::access;

      template <class Archive>
      void serialize(Archive & i_ar, const unsigned int i_version)
        {
        i_ar & m_delay_before;
        i_ar & m_delay_after;
        i_ar & m_next_operation;
        }

      virtual void DoOperate(){};

      boost::shared_ptr<IOperation> m_next_operation;
      unsigned int m_delay_before, m_delay_after;
    };

BOOST_SERIALIZATION_ASSUME_ABSTRACT(IOperation)

//------------------------------------------------------------------------

  class NullOperation : public IOperation
    {
    public:
      NullOperation(unsigned int i_delay = 0);
    private:
      virtual void DoOperate(){};
    };

//------------------------------------------------------------------------
  }


